package com.yesep.learn.design.common.pojo;

public class StorageComponent extends ComputerComponent {
    public StorageComponent() {

    }

    public StorageComponent(String model, double consumption) {
        this();
        setModel(model);
        setConsumption(consumption);
    }

    public byte[] read(long lba, int size) {
        byte[] buffer = new byte[size];
        System.out.printf("The %s %s is reading %s bytes from LBA %s into buffer. \n", this.getClass().getSimpleName().toLowerCase(), getModel(), size, lba);
        return buffer;
    }
}
